R for Spatial Statistics

 

R as a GIS?

While I don't recommend using R as a GIS, there is a good tutorial at:

http://pakillo.github.io/R-GIS-tutorial/

The code below will read a shapefile into R and then will access the third column of values in the attribute table.

library(maptools)
TheShapePoints=readShapePoints("D:\\County_Humboldt\\celltowsp.shp")
TheAttributes=TheShapePoints@data
print(TheAttributes[3])